//
// Created by Administrator on 2024/1/5.
//

#pragma once

#ifndef KD_DECL_LIBRARY
#define KD_DECL_LIBRARY
#if defined(_MSC_VER) || defined(_WIN64) || defined(_WIN64) || defined(__WIN64__) || defined(WIN32) \
|| defined(_WIN32) || defined(__WIN32__) || defined(__NT__)
#define KD_DECL_EXPORT __declspec(dllexport)
#define KD_DECL_IMPORT __declspec(dllimport)
#define KD_DECL_API(type) __declspec(dllexport) type __cdecl
#else
#define KD_DECL_EXPORT __attribute__((visibility("default")))
#define KD_DECL_IMPORT __attribute__((visibility("default")))
#define KD_DECL_API(type) __attribute__((visibility("default"))) type
#endif
#endif


#include <iostream>

class KD_DECL_EXPORT MyLog
{
public:
    virtual ~MyLog();
    static MyLog &instance();
    template <typename T>
    void log(const T &t) {
        std::cout << t << std::endl;
    }
private:
    explicit MyLog();
};
